﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using notepadplus.Classes.Editor;
using System.Drawing;
using notepadplus;

namespace notepadplus.Classes.TabManager
{
    internal class TabsWorkflow
    {
        MainWindow mw;
        public void addpage(string content, string header, TabControl manager)
        {
            if (mw == null)
                mw = new MainWindow();
            TabPage page = new TabPage();
            EditorWorkflow editor = new EditorWorkflow();
            page.Tag = editor;
            editor.Tag = page;
            manager.TabPages.Add(page);
            page.Controls.Add(editor);
            editor.Dock = DockStyle.Fill;
            page.Text = header;
            editor.Text = content;
            page.ImageIndex = 1;
            page.BorderStyle = BorderStyle.Fixed3D;
            editor.IndentBackColor = Color.Silver;
            editor.ServiceLinesColor = Color.Transparent;
            editor.BackColor = Color.White;
            editor.ShowFoldingLines = false;
            editor.Font = Properties.Settings.Default.monoFont;
        }
    }
}
